import Layout from '@/views/layout'
import Layout2 from '@/views/layout/index2'

const finance = {
  path: '/financeManagement',
  component: Layout2,
  redirect: 'noredirect',
  name: 'financeManagement',
  needAuth: true,
  meta: { title: '金融管理', icon: 'brand' },
  children: [
    {
      path: '/financeHome',
      component: Layout,
      meta: { title: '金融首页', noCache: true, breadcrumb: false },
      redirect: '/financeHome/index',
      name: 'financeHome',
      needAuth: true,
      children: [
        {
          path: 'index',
          name: 'financeHome',
          component: () => import('@/views/financeManage/financeHome'),
          meta: { title: '金融首页', noCache: true },
        }
      ]
    },
    {
      path: '/financeProduct',
      component: Layout,
      meta: { title: '金融产品', noCache: true, breadcrumb: false },
      redirect: '/financeProduct/index',
      name: 'financeProduct',
      needAuth: true,
      children: [
        {
          path: 'index',
          name: 'financeProduct',
          component: () => import('@/views/financeManage/financeProduct/index'),
          meta: { title: '金融产品', noCache: true },
        },
        {
          path: 'add',
          name: 'financeProductAdd',
          component: () => import('@/views/financeManage/financeProduct/add'),
          meta: { title: '新增金融产品', noCache: true },
          hidden: true
        },
        {
          path: 'edit',
          name: 'financeProductEdit',
          component: () => import('@/views/financeManage/financeProduct/edit'),
          meta: { title: '编辑金融产品', noCache: true },
          hidden: true
        },
        {
          path: 'view',
          name: 'financeProductView',
          component: () => import('@/views/financeManage/financeProduct/view'),
          meta: { title: '查看金融产品', noCache: true },
          hidden: true
        },
      ]
    },
    {
      path: '/financeApply',
      component: Layout,
      meta: { title: '金融申请', noCache: true, breadcrumb: false },
      redirect: '/financeApply/index',
      name: 'financeApply',
      needAuth: true,
      children: [
        {
          path: 'index',
          name: 'financeApply',
          component: () => import('@/views/financeManage/financeApply'),
          meta: { title: '金融申请', noCache: true },
        }
      ]
    },
  ]
}

export default finance